#去重复
# a = [1,2,1,3,5,5]
# def func(a):
#     x = []
#     for i in a:
#         if i not in x:
#             x.append(i)
#     print(x)
# A = func(a)

#在文件里去除空格展示
# with open('text.txt','r',encoding='utf8') as f:
#     a = f.readlines()
#     print(a)
#     lst2 = []
#     for i in a:
#         a = i.split(',')
#         # print(a)
#         lst1=[]
#         for j in a:
#             c = int(j.strip(','))
#             print(c)
#
#             lst1.append(c)
#             print(lst1)
#         lst2.append(tuple(lst1))
#     print(lst2)


#判断（是否正确
# a = '(1+2)+(3+4)'
# def func(a):
#     lef = '('
#     rig =')'
#     lst_1=[]
#     if a.count('(') == a.count(")"):
#         for i in range(len(a)):
#             if a[i] ==lef:
#                 lst_1.append(a[i])
#             elif a[i] == rig:
#                 lst_1.remove('(')
#         return True
#
#     else:
#         return False
#
#
# A=func(a)
# print(A)


#找唯一不重复的
# a= [1,2,2,1,3,3,4,5,4,5,8]
# lst1 = []
# def func(a):
#     lst1 = list(set(a))
#     for i in lst1:
#         c = 0
#         for j in a:
#             if i == j:
#                 c +=1
#         if c == 1:
#             return i
# A = func(a)
# print(A)

# #小球高处垂直掉落每次反弹1/3次计算最后一次高度和总弹起高度
# def func(a,b):
#     c = 0
#     for i in range(1,b+1):
#         # print(i)
#         hei = a*(1/3)**i
#         c = c+hei
#     print('第%d次高度:%.2f,总高度:%.2f,' % (i,hei,c))
# A=func(100,3)

#青蛙跳台阶 有多少中跳法
#1阶  1种
#2阶  3种
#3阶  6种
#4阶
#






























